package com.kaishengit.service;

import java.util.List;

import com.kaishengit.dao.FileDao;
import com.kaishengit.dao.FileShareDao;
import com.kaishengit.entity.FileShare;
import com.kaishengit.entity.Files;
import com.kaishengit.util.GetTime;
import com.kaishengit.util.Pager;

public class FileShareService {
	FileShareDao fsdao = new FileShareDao();
	public Pager findAll(String pid,int num) {
		return fsdao.findAll(pid, num);
	}
	public Pager findAllFile(String fsid, int presentNum) {
		FileDao fdao = new FileDao();
		return fdao.findAll(fsid,presentNum);
	}
	public FileShare findBy1Id(String fsid) {
		
		return fsdao.findById(fsid);
	}
	public void insert(String value, String fileName, long fileSize,
			String mid, String fsid) {
		String fid = GetTime.getTime();
		FileDao fdao = new FileDao();
		Files f = new Files();
		f.setF_id(fid);
		f.setF_name(value);
		f.setF_pathName(fileName);
		//f.setF_size(f_size);
		//fdao.insert()
	}
	

}
